<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <title>Animus</title>
        <meta name="description" content="" />
        <link href="<?php echo base_url() . 'assets/css/home/style.css' ?>" rel="stylesheet" type="text/css" media="screen" />
        <script type="text/javascript" src="<?php echo root_url('animus') . 'assets/jquery/'; ?>jquery-1.4.3.min.js"></script>
        <script type="text/javascript" src="<?php echo root_url('animus') ?>assets/fancybox/jquery.fancybox-1.3.2.js"></script>
        <link rel="stylesheet" type="text/css" href="<?php echo root_url('animus') ?>assets/fancybox/jquery.fancybox-1.3.2.css" media="screen" />
        <script type="text/javascript">
                $(document).ready(
                function(){
                     $('.list  tr:even').addClass('highlight');
                    $("a#example5").fancybox();
                    $("#various3").fancybox({
                        'width'				: '50%',
                        'height'			: '130%',
                        'autoScale'			: false,
                        'transitionIn'		: 'none',
                        'transitionOut'		: 'none',
                        'type'				: 'iframe'
                    });
                }
            );
            </script>
    </head>
    <body leftmargin="0" topmargin="0" marginheight="0" marginwidth="0">
        <div id="wrapper-top" align="center">
            <table width="1000px">
                <tr>
                    <td width="210px" valign="top"><a href="<?php echo base_url(); ?>"><img src="<?php echo base_url() . '/assets/css/home/image/logo.png'; ?>" border="0" /></a></td>
                    <td id="wrapper-menu" valign="top">
                        <div id="menu">
                            <ul>
                                <li><a href="<?php echo root_url('animus');?>"><img src="<?php echo base_url() . '/assets/css/home/image/home.png'; ?>" border="0"/></a></li>
                                <li><a href="<?php echo root_url('animus') . 'seatting-falin' ?>">SEATING-FALLIN</a></li>
                                <li><a href="<?php echo root_url('animus') . 'zoo-market' ?>">ZOO-MARKET</a></li>
                                <li><a href="<?php echo base_url(); ?>">ANIMUS</a></li>
                                <li><a href="<?php echo root_url('animus') . 'doggy-flirt' ?>">DOGGY-FLIRT</a></li>
                            </ul>

                        </div>
                        <!--END MENU-->
                    </td>
                </tr>
            </table>
        </div>
        <!--END WARPPER TOP-->

        <div id="wrapper" align="center">
            <div id="contain" align="center">
                <img src="<?php echo base_url() . '/assets/css/home/image/border_left.png'; ?>" style="left:0px" class="contain_border" />
                <img src="<?php echo base_url() . '/assets/css/home/image/border_right.png'; ?>" style="right:0px" class="contain_border" />
<!--                <div id="wrapper-actu" align="center">-->
                    <?php
                        $login_style = 'style="height:204px;"';
                        if($this->session->userdata('user_id')==TRUE){
                            $login_style='style="height:180px;"';
                        }
                        if($login_error){
                            $login_style='style="height: 254px;"';
                        }
                        if($validate_error){
                            $login_style='style="height: 274px;"';
                        }
                    ?>
                    <?php if(count($alaune_annonce)>0) {?>
                    <div id="top_box_index">
                        <span class="top_box_top"></span>
                        <div class="content">
                        <?php for($index=0;$index<count($alaune_annonce); $index++) {?>
                        <?php
                            $image_path = "./assets/annonce/thumbs/" . $alaune_annonce[$index]['images'];
                            if ($alaune_annonce[$index]['images'] != '') {
                                if (file_exists($image_path)) {
                                    $image_path = base_url() . "assets/annonce/thumbs/" . $alaune_annonce[$index]['images'];
                                } else {
                                    $image_path = root_url('animus') . "assets/noimage.gif";
                                }
                            } else {
                                $image_path = root_url('animus') . "assets/noimage.gif";
                            }
                        ?>
                            <div class="top_box_block <?php if(($index+1)%4==0) echo ' no_margin_r';?>">
                                <h4><?php echo get_short_description($alaune_annonce[$index]['title'],5); ?></h4>
                                <br/>
                                <a href="<?php echo site_url('annonce/detail_annonce/' . $alaune_annonce[$index]['id']); ?>">
                                    <img border="1" class="icon" src="<?php echo $image_path?>" alt=""/>
                                </a>
                            </div>
                        <?php }?>
                            <div class="top_box_block_a"><a href="<?php echo site_url('annonce/list_annonce'); ?>" style="color:#5d94c5;">>>> </a></div>
                        </div>
                    </div>
                    <?php } ?>
                    <div id="actu" align="center">
                        <div id="creeranonce"> <a href="<?php echo site_url('annonce/add_new_annonce'); ?>"><img src="<?php echo base_url() . '/assets/css/home/image/creeranonce.png'; ?>"/></a></div>
                        <div id="login" align="center" <?php echo $login_style;?> >
                            <img src="<?php echo base_url() . '/assets/css/home/image/bgrtop_login.png'; ?>" class="bgrtop" />
                            <img src="<?php echo base_url() . '/assets/css/home/image/bgrbottom_login.png'; ?>" class="bgrbottom" />
                            <div class="contenu">

                                <?php if ($this->session->userdata('user_id') == NULL) {
 ?>
                                    <!-- LOGIN FORM-->
<?php $this->load->view('home/user/login_form'); ?>
                                    <!-- End LOGIN FORM-->
<?php } else { ?>
                                    <!-- LOGOUT FORM -->
<?php $this->load->view('home/user/logout_form') ?>
                                    <!-- End Logout FORM-->
<?php } ?>


                            </div><!--END CONTENU-->
                        </div><!--END LOGIN-->